import { PLATFORM_NAME, PLATFORM_ORG } from '../../plugins/constant'

export default {
  path: '/',
  component: () => import(/* webpackChunkName: "gov-app" */ '@/gov/views/Layout.vue'),
  redirect: { name: 'credit_index' },
  meta: { root: true, title: PLATFORM_NAME, org: PLATFORM_ORG },
  children: [
    {
      path: 'credit',
      component: { render: h => h('router-view') },
      redirect: { name: 'credit_index' },
      meta: { title: '信用服务', icon: 'fa fa-fw fa-home', hidden: true },
      children: [
        {
          path: 'index',
          component: { render: h => h('router-view') },
          meta: { title: '主页', icon: 'fa fa-home' },
          children: [
            {
              path: '',
              name: 'credit_index',
              component: () =>
                import(/* webpackChunkName: "gov-index" */ '@/gov/views/bus/index/Index.vue'),
              meta: {},
            },
            {
              path: 'class',
              name: 'index_class_nav',
              component: () =>
                import(/* webpackChunkName: "gov-index" */ '@/gov/views/bus/index/NavClass.vue'),
              meta: { title: '产业专班' },
            },
          ],
        },
        {
          path: 'import',
          component: { render: h => h('router-view') },
          meta: {
            title: '项目推荐',
            icon: 'fa fa-list-ul',
            defaultOpened: true,
            name: 'govApproval',
          },
          redirect: { name: 'import_class' },
          children: [
            {
              path: 'class',
              name: 'import_class',
              component: () =>
                import(
                  /* webpackChunkName: "gov-import" */ '@/gov/views/bus/import/class/Index.vue'
                ),
              meta: { title: '产业专班项目', hidden: true },
            },
            {
              path: 'xinnong',
              name: 'import_xinnong',
              component: () =>
                import(
                  /* webpackChunkName: "gov-import" */ '@/gov/views/bus/import/xinnong/Index.vue'
                ),
              meta: { title: '新农直报项目' }, // , scope: 'dirReport'
            },
          ],
        },
        {
          path: 'recom',
          name: 'track_recom',
          component: () =>
            import(/* webpackChunkName: "gov-track" */ '@/gov/views/bus/track/recom/Index.vue'),
          meta: { title: '项目受理', icon: 'fa fa-send' },
        },
        {
          path: 'register',
          name: 'track_register',
          component: () =>
            import(/* webpackChunkName: "gov-track" */ '@/gov/views/bus/register/Index.vue'),
          meta: { title: '放款登记', icon: 'fa fa-file-text' },
        },
        {
          path: 'track',
          name: 'track_index',
          component: () =>
            import(/* webpackChunkName: "gov-track" */ '@/gov/views/bus/track/track/Index.vue'),
          meta: { title: '项目跟踪', icon: 'fa fa-random' },
        },
        // {
        //   path: 'data',
        //   component: { render: h => h('router-view') },
        //   name: 'data_index',
        //   meta: { title: '数据管理', icon: 'fa fa-address-card' },
        //   children: [
        //     {
        //       path: 'ic',
        //       name: 'datas_ic',
        //       component: () =>
        //         import(/* webpackChunkName: "gov-datas" */ '@/gov/views/datas/IC.vue'),
        //       meta: { title: '工商数据' },
        //     },
        //     {
        //       path: 'family',
        //       name: 'datas_family',
        //       component: () =>
        //         import(/* webpackChunkName: "gov-datas" */ '@/gov/views/datas/Family.vue'),
        //       meta: { title: '家庭成员' },
        //     },
        //     {
        //       path: 'scale',
        //       name: 'datas_scale',
        //       component: () =>
        //         import(/* webpackChunkName: "gov-datas" */ '@/gov/views/datas/Scale.vue'),
        //       meta: { title: '经营规模' },
        //     },
        //     {
        //       path: 'insurance',
        //       name: 'datas_insurance',
        //       component: () =>
        //         import(/* webpackChunkName: "gov-datas" */ '@/gov/views/datas/Insurance.vue'),
        //       meta: { title: '保险信息' },
        //     },
        //     {
        //       path: 'subsidy',
        //       name: 'datas_subsidy',
        //       component: () =>
        //         import(/* webpackChunkName: "gov-datas" */ '@/gov/views/datas/Subsidy.vue'),
        //       meta: { title: '补贴数据' },
        //     },
        //     {
        //       path: 'power',
        //       name: 'datas_power',
        //       component: () =>
        //         import(/* webpackChunkName: "gov-datas" */ '@/gov/views/datas/Power.vue'),
        //       meta: { title: '用电数据' },
        //     },
        //     {
        //       path: 'machinery',
        //       name: 'datas_machinery',
        //       component: () =>
        //         import(/* webpackChunkName: "gov-datas" */ '@/gov/views/datas/Machinery.vue'),
        //       meta: { title: '农机数据' },
        //     },
        //   ],
        // },
      ],
    },
  ],
}
